﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Helpers
{
    public class RandomHelper
    {
        private static Random ran = new Random(Environment.TickCount);

        /// <summary>
        /// 返回一个小于所指定最大值的非负随机数。
        /// </summary>
        /// <param name="maxValue">要生成的随机数的上限（随机数不能取该上限值）。maxValue 必须大于或等于零。</param>
        /// <returns></returns>
        public static int Next(int maxValue)
        {
            return ran.Next(maxValue);
        }
    }
}
